import React, { useState } from "react";

function TestComponent() {
  const [data, setData] = useState<string>();

  setTimeout(() => {
    setData("Hello World");
  }, 3000);

  return <div>{data}</div>;
}
export default TestComponent;
